import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
//import Table from './views/nav1/Table.vue'
//import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import Order from './views/pet/SearchMasterMsgPending'
import Pet from './views/pet/Pet'
import Service from './views/service/Service'
import echarts from './views/charts/echarts.vue'

/*自己的组件*/
import Dept from './views/org/Dept.vue'
import Employee from './views/org/employee.vue'
import Shop from './views/org/Shop.vue'
import shopReg from './views/ShopRegister.vue'
import RejectReg from './views/RejectRegister'

let routes = [
    {
        path: '/login',
        component: Login,
        name: '',
        hidden: true
    },
    {
        path: '/shopReg',
        component: shopReg,
        name: '',
        hidden: true
    },
    {
        path: '/rejectReg',
        component: RejectReg,
        name: '',
        hidden: true
    },
    {
        path: '/404',
        component: NotFound,
        name: '',
        hidden: true
    },
    //{ path: '/main', component: Main },
    {
        path: '/',
        component: Home,
        leaf: true,
        name: 'Charts',
        iconCls: 'fa fa-bar-chart',
        children: [
            { path: '/echarts', component: echarts, name: 'echarts' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '组织机构',
        iconCls: 'el-icon-message',//图标样式class
        children: [
            { path: '/main', component: Main, name: '主页', hidden: true },
            { path: '/dept', component: Dept, name: '部门管理' },
            { path: '/employee', component: Employee, name: '人员管理' },
            { path: '/shop', component: Shop, name: '店铺管理' },
        ]
    },
    {
        path: '/',
        component: Home,
        name: '宠物管理',
        iconCls: 'fa fa-id-card-o',
        children: [
            { path: '/pet', component: Pet, name: '宠物' },
            { path: '/order', component: Order, name: '我的订单' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '服务',
        iconCls: 'fa fa-address-card',
        children: [
            { path: '/service', component: Service, name: '服务' }
        ]
    },
    {
        path: '*',
        hidden: true,
        redirect: { path: '/404' }
    }
];

export default routes;